home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / docs / howto / makeKernelChanges < prev    next >
Encoding:
Text File  |  1992-12-14  |  2.5 KB  |  53 lines

  1. Here are a few guidelines on how to make kernel changes without stepping
  2. on other people.
  3.  
  4.     Quick, compatible changes:
  5. If you have a quick change to make (1 day's work or less), and this change
  6. is not visible outside of its own module, then go ahead and make the change
  7. in the uninstalled copy of that module.
  8.  
  9.     Longer or incompatible changes:
  10. If your changes are visible outside of a particular module or would require
  11. keeping files checked out for more than a day, then make a snap-shot of the
  12. modules you need to change and do your work in those copies.  You will also
  13. need to make snap-shots of the modules your changes affect.
  14.  
  15.     Incompatible changes to header files:
  16. To make changes to a header file that would affect other people, create a
  17. directory in /sprite/src/kernel called something like "hdrs.name" where name
  18. is your login name or initials.  Put a link to, or copy of, your changed header
  19. file in this directory.  Then, in your home directory, create a file named
  20. kernel.mk.  Put the line
  21.  
  22. CFLAGS += -I/sprite/src/kernel/hdrs.name
  23.  
  24. in this file.  Then, when you compile your modules, the first place a
  25. header file will be looked for is in hdrs.name.  If it's not found there,
  26. it will be picked up from the standard places.
  27.  
  28.     Merging your changes back into the public modules:
  29. After you have tested your changes, merge them into the uninstalled modules.
  30. Merging changes usually doesn't take much longer than a day, and the installed
  31. modules are still available while you're hacking in the uninstalled modules.
  32. It might be nice to send mail to spriters telling them that you are doing
  33. this to the uninstalled modules.
  34.  
  35.     Installing your changes:
  36. After you have merged and tested your changes, it's okay to install them.
  37. Install all the modules you need to install in order to make the set
  38. of installed modules compatible with each other.  You do not need to install
  39. a whole new kernel.
  40.  
  41.     Changes to kernel structures visible to user programs:
  42. This is a mess.  Let's say you have made a change to the Fs_Stat structure.
  43. This means the user program fsstat may no longer work.  You can write a
  44. script called fsstat that grabs the kernel version and picks either fsstat.old
  45. or fsstat.new to exec.  For spring cleaning, let's hope we do something
  46. more pleasant to solve this problem.
  47.  
  48.     Sending email:
  49. It's an admirable thing to send mail to spriters advising them of any
  50. changes that may affect them.  If you install a module, for instance, it's
  51. pleasant to let people know about this, so they can come and harass you
  52. later if the module has broken something.
  53.